package pattern9.draw_people;

/**
 * 人的构建的指挥者
 * @author wdl
 */
public class PersonDirector {
    BasePersonBuilder personBuilder;

    /**
     * @param personBuilder 告知指挥者需要画的人
     */
    public PersonDirector(BasePersonBuilder personBuilder){
        this.personBuilder=personBuilder;
    }

    /**
     * 根据用户选择建造小人
     */
    public void drawPerson(){
        personBuilder.buildHead();
        personBuilder.buildBody();
        personBuilder.buildArmsAndLegs();
    }
}
